﻿using GraphProcessor;
using IQIGame.Onigao.Logic;
using UnityEngine;

namespace IQIGame.Onigao.GamePlay.Editors
{
    [System.Serializable, NodeMenuItem(SkillEditorConst.Trigger + "/" + SkillEditorConst.AddBuff, typeof(SkillEditorGraph))]
    public class SkillTriggerNode_AddBuff : SkillTriggerNode
    {
        protected override ESkillTriggerType type => ESkillTriggerType.AddBuff;

        public int buffID;
        public int tag;
        [InspectorName("自身添加给别人")]public bool selfAdd;
        [InspectorName("别人添加给自己")]public bool selfTarget;
        
        protected override SkillCustomConfig CreateConfig()
        {
            return new SkillTrigger_AddBuff_ConfigData()
            {
                buffID = this.buffID,
                tag = this.tag,
                selfAdd = this.selfAdd,
                selfTarget = this.selfTarget,
            };
        }
    }
}